﻿namespace MXERP.Shared.Wrapper
{
    public class PageResponse<T> where T : class
    {
        /// <summary>
        /// 数据总数
        /// </summary>
        public int TotalCount { get; set; }
        /// <summary>
        /// 每页大小
        /// </summary>
        public int PageSize { get; set; }
        /// <summary>
        /// 当前页码
        /// </summary>
        public int PageIndex { get; set; }

        public int TotalPage
        {
            get { return (TotalCount + PageSize - 1) / PageSize; } 
        }

        public List<T>? List { get; set; }
    }
}
